//
//  RouterBridgeManager.m
//  Loan
//
//  Created by WuShiHai on 17/04/2017.
//  Copyright © 2017 Shanghai Mengdian Information Technology Co., Ltd. All rights reserved.
//

#import "WDRouterModule.h"
#import <WDReact/WDReact.h>
#import <WDRouter/WDRouter.h>

@implementation WDRouterModule

RCT_EXPORT_MODULE(router);

RCT_EXPORT_METHOD(registerRouter:(NSString *)path page:(NSString *)page){
    WD_REGISTER_REACT_ROUTER(path,page);
}

RCT_EXPORT_METHOD(openURL:(NSString *)url){
    beginExecInMainBlock
    [WDRouter openURL:url];
    endExecInMainBlock
}

@end
